package com.example.shirodemo.mapper;

import com.example.shirodemo.controller.vo.RolePermissionVo;
import com.example.shirodemo.entity.SRolePermission;
import java.util.List;
import org.apache.ibatis.annotations.Param;

/**
 * @Author 绫小路
 * @Date 2021/1/15
 */

public interface SRolePermissionMapper {

  int deleteByPrimaryKey(Integer id);

  int insertSelective(SRolePermission record);

  SRolePermission selectByPrimaryKey(Integer id);

  int updateByPrimaryKeySelective(SRolePermission record);

  List<RolePermissionVo> get(@Param("roleId") Integer roleId, @Param("search") String search);

  int has(@Param("roleId") Integer roleId, @Param("permissionId") Integer permissionId);

  int deleteAll(@Param("roleId") Integer roleId);

  int delete(@Param("roleId") Integer roleId, @Param("permissionId") Integer permissionId);
}
